package ac.neec.util;

public class HeartRateCompute {
	private static final int COEFFICIENT = 220;
	public static int calcTargetHeartRateKarvonen(int age, int restHeartRate, float sportsLevel){
		return (int) (((COEFFICIENT - age) - restHeartRate) * sportsLevel + restHeartRate);
	}

	public static int calcTargetHeartZeroToPeak(int age, float sportsLevel){
		return (int) ((COEFFICIENT - age) * sportsLevel);
	}
}
